package jjn.round1;

/**
 * @author Jjn
 * @since 2022/8/3 23:29
 */
public class GuessGame {
    private Integer picked;
    private Integer max;

    public GuessGame(Integer max, Integer picked) {
        this.picked = picked;
        this.max = max;
    }

    public int guess(int value) {
        if (value == picked) {
            return 0;
        }
        if (value < picked) {
            return -1;
        }
        return 1;
    }
}
